﻿<Window
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    x:Class="Copy4Backup.MainWindow"
    Title="Copy4Backup" Height="300" Width="341" 
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"
    Loaded="Window_Loaded" Closing="Window_Closing" Icon="/Copy4Backup;component/Copy4Backup.ico">

    <Window.Resources>
        <Style TargetType="{x:Type Button}">
            <Setter Property="Margin" Value="5"/>
            <Setter Property="Width" Value="50"/>
        </Style>

        <Style TargetType="{x:Type TextBlock}">
            <Setter Property="Margin" Value="5"/>
        </Style>
    </Window.Resources>
    
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="auto"/>
            <RowDefinition/>
            <RowDefinition Height="auto"/>
        </Grid.RowDefinitions>
        
        <TextBlock Grid.Row="0"><Run Text="Project list"/></TextBlock>
        
        <ListBox Grid.Row="1" x:Name="listBoxProjects" Margin="5" TabIndex="0" 
                 DataContext="{Binding}"
                 DisplayMemberPath="Name"
                 IsSynchronizedWithCurrentItem="True" />
        
        <StackPanel Grid.Row="2" Orientation="Horizontal" HorizontalAlignment="Center">
            <Button x:Name="buttonAdd" Click="buttonAdd_Click" TabIndex="1" Content="_Add" />
            <Button x:Name="buttonEdit" Click="buttonEdit_Click" TabIndex="2" Content="_Edit"/>
            <Button x:Name="buttonDelete" Click="buttonDelete_Click" TabIndex="3" Content="_Delete"/>
            <Button x:Name="buttonExecute" Click="buttonExecute_Click" TabIndex="4" Content="E_xeute"/>
            <Button x:Name="buttonAbout" Click="buttonAbout_Click" TabIndex="5" Content="About"/>
        </StackPanel>
    </Grid>
</Window>
